RemoteAudioState enum Null safety

用户订阅的远端音频流状态,及在 RemoteAudioStateChangeReason 中对应的原因

Constants

decoding → const RemoteAudioState

远端音频流正在解码,正常播放,该状态回调时机包括:

  • 成功解码远端音频首帧,对应原因是 localUnmuted
  • 网络由阻塞恢复正常,对应原因是 networkRecovery
  • 本地用户恢复接收远端音频流,对应原因是 localUnmuted
  • 远端用户恢复发送音频流,对应原因是 remoteUnmuted
const RemoteAudioState(2)
failed → const RemoteAudioState

远端音频流播放失败

该错误码暂未使用

const RemoteAudioState(4)
frozen → const RemoteAudioState

远端音频流卡顿。

网络阻塞导致丢包率大于 40% 时回调该状态,对应原因是 networkCongestion

const RemoteAudioState(3)
starting → const RemoteAudioState

开始接收远端音频流首包

刚收到远端音频流首包时,会触发回调 RTCVideoEventHandler.onRemoteAudioStateChanged,对应原因是 localUnmuted。

const RemoteAudioState(1)
stopped → const RemoteAudioState

远端音频流默认初始状态,该状态回调时机包括:

  • 本地用户停止接收远端音频流,对应原因是 localMuted
  • 远端用户停止发送音频流,对应原因是 remoteMuted
  • 远端用户离开房间,对应原因是 remoteOffline
const RemoteAudioState(0)
values → const List<RemoteAudioState>

A constant List of the values in this enum, in order of their declaration.

const List<RemoteAudioState>

Properties

hashCode → int
The hash code for this object. [...]
read-only, inherited
index → int

The integer index of this enum.

final
runtimeType → Type
A representation of the runtime type of the object.
read-only, inherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() → String
A string representation of this object. [...]
override

Operators

operator ==(Object other) → bool
The equality operator. [...]
inherited